
<%@ page language="java" pageEncoding="ISO-8859-1"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<jsp:useBean id="projectbean" type="dtt.ProjectBean" scope="request" />
<jsp:useBean id="defectbean" type="dtt.DefectBean" scope="request" />

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>add defect content </title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	
	<link rel="stylesheet" type="text/css" href="styles.css">
	
  <script type="text/javascript">

  function validateForm(){
  if(window.defectform.DefectID.value == ''){
  alert('Please enter a valid defect number');
  return false;	
  };
  }//end function
  </script>

<style type="text/css">@import url(jscalendar-1.0/calendar-win2k-1.css);</style>
<script type="text/javascript" src="calendar.js"></script>
<script type="text/javascript" src="calendar-en.js"></script>
<script type="text/javascript" src="calendar-setup.js"></script>
  </head>
  
  <body>
  <form id="adddefectform" action="servlet/FrontController" method="post">

  <br>
    <table valign="top" border="0" align="center" width="85%">
      <tr>
       <td><b>Project Number</b></td>
      <td><b>Project Description</b></td>
      <td><b>Project Category</b></td>
       </tr>
      <tr>
      <td>
      <input readonly type="text" name="projectId1" value="<%= projectbean.getProjectId()%>">
      <input type="hidden" name="projectId" value="<%= projectbean.getProjectId()%>">
      </td>
      <td>
      <input readonly type="text" name="projectDesc1" value="<%= projectbean.getProjectDesc()%>" >
      <input type="hidden" name="projectDesc" value="<%= projectbean.getProjectDesc()%>" >
      </td>
      <td>
      <input type="text" name="projectCategory1" value="<%= projectbean.getProjectCategory()%>" >
      <input type="hidden" name="projectCategory" value="<%= projectbean.getProjectCategory()%>" >
      </td>
      </tr>
      
      <tr>
       <td></td>
      <td></td>
      <td></td>
       </tr>
      
      <tr>
       <td><b>Requirement ID</b></td>
      <td><b>Script ID</b></td>
      <td><b>Defect Number</b> </td>
       </tr>
      <tr>
      <td>  <input type="text" name="requirementId"></td>
      <td>  <input type="text" name="scriptIdnumber"></td>
      <td>
      <input type="text" name="defectId" value="<%=defectbean.getDefectId() %>">
      </td>
      </tr>
      
      <tr>
       <td></td>
      <td></td>
      <td></td>
       </tr>
      
      <tr>
       <td><b>Date Submitted</td>
      <td><b>Severity</td>
      <td><b>Priority</td>
       </tr>
      <tr>
     
      <td>  
      <input type="text" name="defectDateSubmitted " id="dateselect"><input type="reset" id="trigger" value=" ..." onclick="return showCalendar('dateselect', '%a, %b %e, %Y [%I:%M %p]', '12');">
      <script type="text/javascript">
  Calendar.setup(
    {
      inputField  : "dateselect",         // ID of the input field
      ifFormat    : "%m/%d/%Y",    // the date format
      button      : "trigger"       // ID of the button
    }
  );
</script> </td>
      <td><input type="text" name="defectSeverity"></td>
      <td><input type="text" name="defectPriority"></td>
      </tr>
      
       <tr>
       <td></td>
      <td></td>
      <td></td>
       </tr>
      
      <tr>
       <td><b>Reported By</td>
      <td><b>Can Be Reproduced</td>
      <td><b>Status</td>
       </tr>
      <tr>
       <td><input type="text" name="defectReporterName"></td>
       <td>  <input type="text" name="defectReproducibility"></td>
       <td>  <input type="text" name="defectStatus" value="Submitted">  </td>
      </tr>
      
       <tr>
       <td></td>
      <td></td>
      <td></td>
       </tr>
      
      <tr>   
      <td><b>Product Version Number</td>
      <td><b>Build Number</td>
      <td><b>Target Version Number</td>
       </tr>
      <tr> 
      <td><input type="text" name="defectProductVerNbr"></td>
      <td>  <input type="text" name="defectBuildNbr"></td>
      <td><input type="text" name="defectTgtVerNbr"></td>
      </tr>
      
       <tr>
       <td></td>
      <td></td>
      <td></td>
       </tr>
      
      </table>
  	 <table valign="top" border="0" align="center" width="85%">
  	  <tr>
  	 <td><b>Description  </td>
  	 </tr>
  	 <tr>
  	  <td>
  	 <textarea name="defectDesc" rows="1" cols="80"></textarea>
  	 </td>
  	 </tr>
  	 </table>
  	 
  	 <table valign="top" border="0" align="center" width="85%" cellspacing="2" cellpadding="2">
  	 <tr>
  	 <td> <b>Steps To Reproduce the Defect</td>
  	 <td><b> Development Repair Comments</td>
  	 </tr>
  	 <tr>
  	  <td>
  	 <textarea name="defectStepstoReproduce" rows="15" cols="40"></textarea>
  	 </td>
  	 <td>
  	 <textarea name="defectDevFixComments" rows="15" cols="40"></textarea>
  	 </td>
  	 </tr>
  	 <tr>

  	 </tr>
  	 </table>
  	 
  	 <br>
  	 <center> 
  	 <table cellspacing="2" cellpadding="2">  
       <tr>
       <td><a href="/uploadbean/SimpleUpload.jsp">upload attachment </a> </td>
       <td><input type="Submit" name="DTT_ACTION" value="ADD_DEFECT">ADD </td>
       <td width="20%"> </td>
      <td><input type="Submit" name="DTT_ACTION" value="DEFECT_LIST" >CANCEL</td>
       
      
       </tr>
  	
  	 </table>
  	  </form>
  </body>
</html>
	